package com.cdyZuul.config;

import entity.authToken;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.util.StringUtils;

/**
 * @author ：cdy
 * @date ：Created in 2020/11/13 10:55
 * @description：www.cdyong.cn
 * 验证令牌业务
 */
@Configuration
public class authTokenConfig {
    @Bean("authToken")
    public authToken authToken(){

        return  new authToken() {
            @Override
            public boolean checker(String token) {
                if(StringUtils.isEmpty(token))
                     return false;

                return  true;
            }
        };
    }
}
